import {  getAction } from '@/api/manage';
export const StuHeartRate = {
  data(){
    return {
      
    }
  },
  props:["dataForm"],
  mounted() {
    this.load();
  },
  methods:{
    // 加载报表
    load() {
      this.initStudentChart();
    },
    queryData(data = {}){
      return new Promise((resolve, reject) => {
        const params = {
          classType:this.dataForm.gradeId,
          classId:this.dataForm.classId,
          studentId:this.dataForm.stuId,
          startDate:this.dataForm.startDate,
          endDate:this.dataForm.endDate,
          dateType:val.dateType
        }
        params = Object.assign(params,data);
        getAction(this.url.query,params).then((res)=>{
          if(res.success){
            resolve(res.result)
          } else {
            this.$message.warning(res.message);
          }
        }).catch((error)=>{
          console.error(error);
        })
      })
    },
  }

}